#region Summary

// 
// Owner : JackieHan 
// 
// Solution : DailyCollection 
// 
// Project : Jackie.Utility.Notify
// 
// File : IService.cs
// 
// CopyRight : Copyright © 2010-2011 Skomart Corporation, All Rights Reserved 
// 
// Summary : 服务接口约束
// 
// History : 
//			2011-04-25 14:51:51	    Create 
// 

#endregion

#region Using

using System;
using System.ServiceModel;
using Jackie.Utility.Notify.Domain;

#endregion

namespace Jackie.Utility.Notify.Contracts
{
    /// <summary> 
    /// 服务接口约束
    /// </summary>
    [ServiceContract]
    public interface IPublish
    {
        /// <summary>
        /// 向服务器发布分发的消息
        /// </summary>
        /// <param name="info"></param>
        /// <returns></returns>
        [OperationContract]
        void SendMessage(MessageInfo info);

        /// <summary>
        /// 向消息服务注册一个可供订阅的消息源
        /// </summary>
        /// <param name="info">消息标题</param>
        /// <returns></returns>
        [OperationContract]
        void RegisteredTitle(TitleInfo info);

        /// <summary>
        /// 向服务器取消一个可供订阅的消息源
        /// </summary>
        /// <param name="titleCode">消息源标题</param>
        /// <returns></returns>
        [OperationContract]
        void CancelTitle(string titleCode);
    }
}